/*
 * @Author: tkp
 * @Date: 2021-11-20 16:39:42
 */
import { Loading } from 'element-ui';

const loadOption =
{
    fullscreen: true,
    lock: true,
    text: '进行中，请稍后...',
    spinner: 'el-icon-loading',
    customClass: 'create-isLoading2',
    background: 'hsla(0,0%,100%,.9)'
}

let loadingInstance;

export default class loadEvents {
    constructor(vueThis) {
        this.vm = vueThis;  //vue中的this  也可以不用
    }
    open() {
        loadingInstance = Loading.service(loadOption);
    }
    close() {
        loadingInstance.close();
    }
}